<template>
    <div>
        <selfMsgVue></selfMsgVue>
        <maybeLoveVue></maybeLoveVue>
        <myBottomNavVue :cart="cart" :my="my" current="2"></myBottomNavVue>
        <!-- <goodListFatherVue :current="1"></goodListFatherVue> -->
        <div class="goodsList">
            <List v-for="(v, index) in arr" :key="index" :img1="v.img1" :proname="v.proname" :originprice="v.originprice" :sales="v.sales" :flag="false" @click.native="goDetail1(v)"></List>
        </div>
    </div>
</template>

<script>
import List from '@/components/xn/HomeCom/Goods/List.vue'
// import goodListFatherVue from '../HomeCom/goodListCom/goodListFather.vue'
import maybeLoveVue from '../MyCom/maybeLove.vue'
import myBottomNavVue from '../MyCom/myBottomNav.vue'
import selfMsgVue from '../MyCom/selfMsg.vue'


export default {
    name:'MyPage',
    data(){
        return {
            cart:"https://img.alicdn.com/imgextra/i3/O1CN0151qDFg2AN4Vma3SdE_!!6000000008190-2-tps-63-63.png",
            my:"https://img.alicdn.com/imgextra/i1/O1CN01gJdKCx1sB10EydwbE_!!6000000005727-2-tps-63-63.png",
            flag:false,
            arr:[]
         
        }
    },  
    methods:{
        goDetail1(v) {
         this.$router.push({
            path: '/detail',
            query: {
               delList: JSON.stringify(v)
            }
         })
        },
    },
    components:{
        selfMsgVue,
        maybeLoveVue,
        myBottomNavVue,
        // goodListFatherVue,
        List
        
    },
    mounted(){
        this.$http({
            url:`http://118.178.238.19:3001/api/pro/recommendlist`,
            method:"get",
            params:{
                count:3
            }
        }).then(res=>{
            this.arr = res.data.data
        })
    }
}
</script>

<style lang="scss" scoped>
    .goodsList {
        width: 7.02rem;
        margin: auto;
        column-count: 2;
        margin-bottom: 1.6rem;
    }  
</style>